package com.boot.web.service;

import com.boot.web.entity.Department;
import com.boot.base.service.BaseService;
import com.boot.web.vo.DepartmentVO;

import java.util.List;

/**
 * 部门信息业务层接口
 * @author 【zhouJie】
 * @date 2020-01-14 17:13:41
 */
public interface DepartmentService extends BaseService<Department> {

    /**
     * 获取部门的父级信息
     * @return
     */
    List<Department> getParentDepartment();

    /**
     * 根据部门的父级ID获取子级部门信息
     * @param parentId
     * @return
     */
    List<DepartmentVO> getChildrenDepartment(Integer parentId);

    /**
     * 保存部门信息
     * @param department
     * @return
     */
    int saveDepartment(Department department);

    /**
     * 修改部门信息
     * @param department
     * @return
     */
    int updateDepartment(Department department);

    /**
     * 批量删除部门信息
     * @param ids
     */
    boolean batchDeleteDepartment(Integer[] ids);

}
